-- GENERATED SPELL FOR [Negaton Screamer] --


function spell0_20875(pUnit, Event) --@Arcane Volley,Self--
pUnit:FullCastSpellOnTarget(36738,pUnit)
pUnit:RegisterEvent('Sorts_20875', 1500, 1)
end

function spell1_20875(pUnit, Event) --@Arcane Volley,Self--
pUnit:FullCastSpellOnTarget(38835,pUnit)
pUnit:RegisterEvent('Sorts_20875', 1500, 1)
end

function spell2_20875(pUnit, Event) --@Damage Reduction: Arcane,Self--
pUnit:FullCastSpellOnTarget(34331,pUnit)
pUnit:RegisterEvent('Sorts_20875', 593, 1)
end

function spell3_20875(pUnit, Event) --@Damage Reduction: Fire,Self--
pUnit:FullCastSpellOnTarget(34333,pUnit)
pUnit:RegisterEvent('Sorts_20875', 573, 1)
end

function spell4_20875(pUnit, Event) --@Damage Reduction: Frost,Self--
pUnit:FullCastSpellOnTarget(34334,pUnit)
pUnit:RegisterEvent('Sorts_20875', 602, 1)
end

function spell5_20875(pUnit, Event) --@Damage Reduction: Holy,Self--
pUnit:FullCastSpellOnTarget(34336,pUnit)
pUnit:RegisterEvent('Sorts_20875', 569, 1)
end

function spell6_20875(pUnit, Event) --@Damage Reduction: Nature,Self--
pUnit:FullCastSpellOnTarget(34335,pUnit)
pUnit:RegisterEvent('Sorts_20875', 541, 1)
end

function spell7_20875(pUnit, Event) --@Damage Reduction: Shadow,Self--
pUnit:FullCastSpellOnTarget(34338,pUnit)
pUnit:RegisterEvent('Sorts_20875', 666, 1)
end

function spell8_20875(pUnit, Event) --@Fireball Volley,Self--
pUnit:FullCastSpellOnTarget(36742,pUnit)
pUnit:RegisterEvent('Sorts_20875', 4500, 1)
end

function spell9_20875(pUnit, Event) --@Fireball Volley,Self--
pUnit:FullCastSpellOnTarget(38836,pUnit)
pUnit:RegisterEvent('Sorts_20875', 4500, 1)
end

function spell10_20875(pUnit, Event) --@Frostbolt Volley,Self--
pUnit:FullCastSpellOnTarget(36741,pUnit)
pUnit:RegisterEvent('Sorts_20875', 5500, 1)
end

function spell11_20875(pUnit, Event) --@Frostbolt Volley,Self--
pUnit:FullCastSpellOnTarget(38837,pUnit)
pUnit:RegisterEvent('Sorts_20875', 5500, 1)
end

function spell12_20875(pUnit, Event) --@Holy Bolt Volley,n/a--
pUnit:FullCastSpellOnTarget(36743,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_20875', 1500, 1)
end

function spell13_20875(pUnit, Event) --@Holy Bolt Volley,n/a--
pUnit:FullCastSpellOnTarget(38838,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_20875', 1500, 1)
end

function spell14_20875(pUnit, Event) --@Lightning Bolt Volley,Self--
pUnit:FullCastSpellOnTarget(36740,pUnit)
pUnit:RegisterEvent('Sorts_20875', 1500, 1)
end

function spell15_20875(pUnit, Event) --@Psychic Scream,Self--
pUnit:FullCastSpellOnTarget(13704,pUnit)
pUnit:RegisterEvent('Sorts_20875', 6296, 1)
end

function spell16_20875(pUnit, Event) --@Shadow Bolt Volley,Self--
pUnit:FullCastSpellOnTarget(36736,pUnit)
pUnit:RegisterEvent('Sorts_20875', 1500, 1)
end

function spell17_20875(pUnit, Event) --@Shadow Bolt Volley,Self--
pUnit:FullCastSpellOnTarget(38840,pUnit)
pUnit:RegisterEvent('Sorts_20875', 1500, 1)
end

function Sorts_20875(pUnit, Event)
local choix_sorts_20875 = math.random(0, 17)
if choix_sorts_20875 == 0 then
pUnit:RegisterEvent('spell0_20875', 1, 1)
end
if choix_sorts_20875 == 1 then
pUnit:RegisterEvent('spell1_20875', 1, 1)
end
if choix_sorts_20875 == 2 then
pUnit:RegisterEvent('spell2_20875', 1, 1)
end
if choix_sorts_20875 == 3 then
pUnit:RegisterEvent('spell3_20875', 1, 1)
end
if choix_sorts_20875 == 4 then
pUnit:RegisterEvent('spell4_20875', 1, 1)
end
if choix_sorts_20875 == 5 then
pUnit:RegisterEvent('spell5_20875', 1, 1)
end
if choix_sorts_20875 == 6 then
pUnit:RegisterEvent('spell6_20875', 1, 1)
end
if choix_sorts_20875 == 7 then
pUnit:RegisterEvent('spell7_20875', 1, 1)
end
if choix_sorts_20875 == 8 then
pUnit:RegisterEvent('spell8_20875', 1, 1)
end
if choix_sorts_20875 == 9 then
pUnit:RegisterEvent('spell9_20875', 1, 1)
end
if choix_sorts_20875 == 10 then
pUnit:RegisterEvent('spell10_20875', 1, 1)
end
if choix_sorts_20875 == 11 then
pUnit:RegisterEvent('spell11_20875', 1, 1)
end
if choix_sorts_20875 == 12 then
pUnit:RegisterEvent('spell12_20875', 1, 1)
end
if choix_sorts_20875 == 13 then
pUnit:RegisterEvent('spell13_20875', 1, 1)
end
if choix_sorts_20875 == 14 then
pUnit:RegisterEvent('spell14_20875', 1, 1)
end
if choix_sorts_20875 == 15 then
pUnit:RegisterEvent('spell15_20875', 1, 1)
end
if choix_sorts_20875 == 16 then
pUnit:RegisterEvent('spell16_20875', 1, 1)
end
if choix_sorts_20875 == 17 then
pUnit:RegisterEvent('spell17_20875', 1, 1)
end
end

function mob20875_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_20875', math.random(1500, 3000), 1)
end

function mob20875_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob20875_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob20875_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(20875, 1, 'mob20875_Action')
RegisterUnitEvent(20875, 2, 'mob20875_Leave')
RegisterUnitEvent(20875, 3, 'mob20875_Kill')
RegisterUnitEvent(20875, 4, 'mob20875_Die')
